In a SiC semiconductor device providing a high breakdown electric field strength, a high electric field is generated due to the high breakdown electric field strength, and when forming an element having the trench gate structure, the high electric field is generated particularly at the bottom of the gate. Therefore, the electric field applied to the gate oxide film is increased, and the life time of the gate oxide film is reduced. In order to prevent this, a structure is provided such that a p-type deep layer to be an electric field relaxation layer is formed in the vicinity of the trench where the trench gate is formed, so that the electric field applied to the trench gate is relaxed.